package cn.edu.scau.cmi.luochenghao.chapter07;

interface Com {
	int add(int a,int b);
}

abstract class A_5 {
	abstract int add(int a,int b);
}

class B_5 extends A_5 implements Com {
	public int add(int a,int b) {
		return a+b;
	}
}

public class E_5 {

	public static void main(String[] args) {
		B_5 b=new B_5();
		Com com=b;
		System.out.println(com.add(12, 6));
		A_5 a=b;
		System.out.println(a.add(10,5));
	}

}
